#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os


def init_dir():
    path = os.path.join(
        os.path.expanduser('~'), os.name == 'nt' and 'xinliFM' or '.xinliFM')
    # if (os.name == 'nt'):
    #     path = 'E:\\sync\\NHK'
    if not os.path.exists(path):
        os.mkdir(path)

    return path


APP_NAME = 'XinliFM'
APP_DIR = init_dir()
CACHE_DIR = os.path.join(APP_DIR, 'cache')
DOWNLOAD_DIR = os.path.join(APP_DIR, 'download')
